package com.chenglu.android.couponcenter.mvp.model;


import com.chenglu.android.common.net.RetrofitClientCL;
import com.chenglu.android.couponcenter.mvp.contract.CouponCenterContract;
import com.chenglu.android.goodsinfo.bean.ShopCouponPage;
import com.chenglu.android.index.bean.TabTitleBean;
import com.chenglu.android.mine.bean.CommonDataBean;
import com.chenglu.android.mine.bean.CouponBean;

import java.util.Map;

import io.reactivex.rxjava3.core.Observable;

/**
 * @author: lyj
 * @Created by Copyright 2023/3/2 Guangzhou Hongma Technology Co., Ltd. All rights reserved.
 *
 */
public class CouponCenterModel implements CouponCenterContract.CouponCenterModel {


    @Override
    public Observable<CouponBean> getCouponList(String token, Map<String,String> map) {
        return RetrofitClientCL.getInstance().getApi().getCouponUserList(token,map);
    }

    @Override
    public Observable<ShopCouponPage> getShopCouponPage(String token, Map<String, String> map) {
        return RetrofitClientCL.getInstance().getApi().getShopCouponPage(token, map);
    }

    @Override
    public Observable<CommonDataBean> getShopCouponreceive(String token, String id) {
        return RetrofitClientCL.getInstance().getApi().getShopCouponreceive(token,id);
    }

    @Override
    public Observable<TabTitleBean> getTabTitle() {
        return RetrofitClientCL.getInstance().getApi().getTabTitle();
    }
}
